Soby Web Components

Soby Validator is a comprehensive validation library for web developers. It is designed to ease the exhausting process of implementing the necessary code for validating data model or form controls. By writing few lines of code, all of the functionality is implemented right away by Soby Validator for you. This allows time to be concentrated on other innovative software aspects. Soby Validator also comes with extensively customizable configuring options. You can also write and integrate your own validators.

Setting up your development environment

You can find the necessary information to set up your environment from here.

Presence Validator

This example demonstrates how to use presence validator in the Soby Validator.
"sobyValidate.GetValidator" method takes one parameter. The parameter is the type of the validator. This method returns the validator for the given type. "Validate" method of the validator, returns as invalid if the given value is one of the following empty, null or valid. It returns as valid if the given value is not any of those values.

 var isValid = sobyValidate.GetValidator(soby_ValidatorTypes.Presence).Validate(null);

Value is

Text Validator

This example demonstrates how to use filtering in the Soby Data Grid.
"AddFilterField" method takes four parameters. First one is the name of the field. Second one is filter value. Third one is type of the field. Fourth one is type of the filter. This method does not trigger data population, it just adds the filterfield which will be used on population.

bookGrid.AddFilterField("Genre", "Picaresque", SobyFieldTypes.Text, SobyFilterTypes.Equal); 

Below functionality uses "FilterResult" method which takes four parameters. First one is the name of the field. Second one is filter value. Third one is type of the field. Fourth one is type of the filter. This method triggers the data population.

bookGrid.FilterResult("Genre", "Picaresque", SobyFieldTypes.Text, SobyFilterTypes.Equal); 

Filter by as contains

View source